<template>
  <div :class="$style.container">
    12
  </div>
</template>

<script>
import http from '../APIService/http'
import { removeToken } from '../util/auth'
export default {
  async asyncData(ctx) {
    try {
      let res = await http.post(`/quit`)
      if (res.code === 0) {
        // ctx.store.commit('REMOVE_USER')
        removeToken()
        window.location.href = '/'
      }
    } catch (err) {
      console.log('logout fail:', err)
    }
  }
}
</script>

<style lang='scss' module>
.container {
}
</style>
